package models

import (
	"github.com/shopspring/decimal"
)

const (
	TARGET                 = "TARGET"
	START_UP_CAPITAL       = "START_UP_CAPITAL"
	INVEST_PERIOD          = "INVEST_PERIOD"
	COEFFICIENT            = "COEFFICIENT"
	ADDICTIONAL_INVESTMENT = "ADDICTIONAL_INVESTMENT"
)

const (
	NEVER        = "NEVER"
	QUARTERLY    = "QUARTERLY"
	TWICE_A_YEAR = "TWICE_A_YEAR"
	MONTHLY      = "MONTHLY"
	YEARLY       = "YEARLY"
)

const (
	YEARS  = "YEARS"
	MONTHS = "MONTHS"
)

type Calculator struct {
	ToCalculate    string          `json:"toCalculate,omitempty" `
	Target         decimal.Decimal `json:"target,omitempty"`
	StartUpCapital decimal.Decimal `json:"startUpCapital,omitempty"`
	InvestPeriod   *InvestPeriod   `json:"investPeriod,omitempty"`
	Coefficient    decimal.Decimal `json:"coefficient,omitempty"`
	ReinvestPeriod string          `json:"reinvestPeriod,omitempty"`
}

type InvestPeriod struct {
	Amount int    `json:"amount,omitempty"`
	Period string `json:"period,omitempty" `
}
